//
//  YLUserInfo.m
//  YLProject
//
//  Created by 张伯林 on 2018/2/1.
//  Copyright © 2018年 WY. All rights reserved.
//

#import "YLUserInfo.h"
@implementation AppUserModel
@end
@implementation YLUserInfo
static YLUserInfo *instance = nil;
+(instancetype)shareInstance{
    static dispatch_once_t onceToken;
    dispatch_once(&onceToken, ^{
        instance = [[YLUserInfo alloc]init];
    });
    return instance;
}
+(instancetype)allocWithZone:(struct _NSZone *)zone{
    if (instance == nil) {
        static dispatch_once_t onceToken;
        dispatch_once(&onceToken, ^{
            instance = [super allocWithZone:zone];
        });
    }
    return instance;
}
-(AppUserModel *)userModel{
    if (!_userModel) {
        _userModel = [[AppUserModel alloc]init];
        if (IS_TEST) {
            _userModel.cs_token = @"BsrScn/YZVdrLZ6qzq1vbkMJMTFXFC6BqqFfOAmSM//K3Lc6isqKl2LjJXHhRFaSTzTnB+hrRH8SM1HTab2TOAZ2vgKo0W9ZTg8WcwkTWqQ=";
            _userModel.uid = @"yl_20180201101023";
            _userModel.headerImage = @"https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1517461122249&di=7f851649859b75eceb8eed18ee4be979&imgtype=0&src=http%3A%2F%2Fimage.tianjimedia.com%2FuploadImages%2F2015%2F209%2F42%2F6H182F668EP9.jpg";
            _userModel.haveLogIn = YES;
            _userModel.nickName = @"bushi";
        }else{
            _userModel.cs_token = @"oZZ2o+WiQcGNZGafgHgtg0MJMTFXFC6BqqFfOAmSM//K3Lc6isqKl5CAXZkcOTqG56qL4K9YP2wSM1HTab2TOAZ2vgKo0W9ZcvJuSbOslnkJ9emR9ncIhw==";
            _userModel.uid = @"yl_20180201101023_01";
            _userModel.headerImage = @"https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1517478601003&di=88a71757912d0ecd27c3ef359d9ef0e3&imgtype=jpg&src=http%3A%2F%2Fimg1.imgtn.bdimg.com%2Fit%2Fu%3D3113153671%2C3782273400%26fm%3D214%26gp%3D0.jpg";
            _userModel.haveLogIn = YES;
            _userModel.nickName = @"我是卟师";
        }
    }
    return _userModel;
}
@end
